{% extends 'base.html' %}
{% block title %} 快启动！！！{% endblock %}
{% block content %}


<h1>

    <span style="color: rgb(149, 229, 20);" >欢迎来到</span><button class="cursive-text" onclick="scrollToBottom()">python启动</button><span style="color: rgb(149, 229, 20);">小组的美食小破站</span>

</h1>




<div >


</div>


{% for post in posts %}

<div height="150">


    <img src="{{post.tuPian_cai}}" width="180" height="125">
    <div height="125" class="block-element">

        <div class="abc" style="color: rgb(149, 229, 20);"><a href="{{post.href_cai}}">菜名：{{post.name_cai}}</a></div>
        <div style="color: rgb(190, 239, 13);">成分：{{post.chengFen_cai}}</div>
        <div style="color: rgb(190, 235, 12);">收藏数：{{post.shoucang_cai}}</div>

    </div>




</div>
   <div>===================================================================</div>
{% endfor %}

<nav aria-label="Page navigation">
    <ul class="pagination  justify-content-left">
        {% if current_page > 1 %}
        <li class="page-item">
            <a class="page-link" href="{{ url_for('index', page=current_page - 1) }}">Previous</a>
        </li>
        {% endif %}

        {% for page_num in range(1, total_pages + 1) %}
        <li class="page-item {% if page_num == current_page %}active{% endif %}">
            <a class="page-link" href="{{ url_for('index', page=page_num) }}">{{ page_num }}</a>
        </li>
        {% endfor %}

        {% if current_page < total_pages %} <li class="page-item">
            <a class="page-link" href="{{ url_for('index', page=current_page + 1) }}">Next</a>
            </li>
            {% endif %}
    </ul>
</nav>

<a class="sticky-square" href="#">顶部</a>



<!-- 在网页底部添加运行时间显示 -->
<footer class="text-muted py-3 mt-5">
    <div class="container">

        <hr>
        <p class="mb-1">网站已运行：{{ uptime }}</p>
        <hr>
    </div>
</footer>

<script>
    function scrollToBottom() {
      document.documentElement.scrollTop = document.documentElement.scrollHeight;
    }
  </script>



{% endblock %}